package com.csw.mario;

import javazoom.jl.decoder.JavaLayerException;
import javazoom.jl.player.Player;

import java.io.BufferedInputStream;
import java.io.FileInputStream;
import java.io.FileNotFoundException;

/**
 * @author A
 * @version 1.0
 * @description: TODO
 * @date 2022/11/14 15:36
 */
public class Music {

    public Music() throws FileNotFoundException, JavaLayerException {
        Player player;
        String str = System.getProperty("user.dir")+"\\src\\Music\\music.wav\\";
        BufferedInputStream inputStream = new BufferedInputStream(new FileInputStream(str));
        player = new Player(inputStream);
        player.play();
    }
}
